<?php

namespace App\Http\Requests\Personal\MyResume;
use App\Http\Requests\Request;

class RegInfoCreateRequest extends Request {
    public function authorize(){
        return true;
    }
    public function rules(){
        return [
            'mobile' => 'required|unique:personal_users,mobile|mobile_verification',
            'mobCode'=>'required|mobile_verification_code:'.$this->mobile,
            'name'=>'required',
            'sex'=>'required',
            'birthday'=>'required',
            'education'=>'required',
            'jobarea1'=>'required',
            'jobsort1'=>'required',
            'intentionjobs'=>'required'
        ];
    }
    public function messages(){
        return [
            'mobile.required' => '手机号码必须填写',
            'mobile.unique' => '该手机号码已存在',
            'mobile.mobile_verification' => '请填写正确的手机号码',
            'mobCode.required' =>'验证码不能为空',
            'mobCode.mobile_verification_code' => '手机号码和发送的验证码不匹配',
            'name.required'=>'姓名必须填写',
            'sex.required'=>'请选择性别',
            'birthday.required'=>'请选择出生日期',
            'education.required'=>'请选择学历',
            'jobarea1.required'=>'请选择工作地区',
            'jobsort1.required'=>'请选择工作岗位',
            'intentionjobs.required'=>'寻求职位必须填写'
        ];
    }
}